//
//  HeaderTableViewCell.m
//  test1
//
//  Created by chen on 16/10/30.
//  Copyright © 2016年 chen. All rights reserved.
//

#import "HeaderTableViewCell.h"
#import "SDCycleScrollView.h"
#import "ButtonOnCell.h"

@interface HeaderTableViewCell ()
@property (weak, nonatomic) IBOutlet ButtonOnCell *btn1;
@property (weak, nonatomic) IBOutlet ButtonOnCell *btn2;
@property (weak, nonatomic) IBOutlet ButtonOnCell *btn3;
@property (weak, nonatomic) IBOutlet ButtonOnCell *btn4;
@property(nonatomic,strong)NSArray *arrBtn ;
@end

@implementation HeaderTableViewCell

- (void)awakeFromNib {
    [super awakeFromNib];
////    self.arrBtn = @[_btn1,_btn2,_btn3,_btn4];
//    
//    _btn1.label.text = @"最新";
//    [_btn1.label setText:@"最新"];
//    [_btn1.label sizeToFit];
//    _btn1.backgroundColor = [UIColor whiteColor];
//    _btn1.titleLabel.text = @"最新";
//    [_btn1 setTitle:@"最新" forState:UIControlStateNormal];
//    _btn1.titleLabel.textColor = [UIColor blackColor];  
//    _btn1.titleLabel.font = [UIFont systemFontOfSize:15];
//    [_btn1 addTarget:self action:@selector(print) forControlEvents:UIControlEventTouchUpInside];
//    NSLog(@"%@",NSStringFromCGRect(_btn1.titleLabel.frame));
}
//- (IBAction)newBtn:(UIButton *)sender {
//    NSLog(@"最新");
//}
- (IBAction)clickBtn:(UIButton *)sender {
    
    [self.delegate sendSender:sender];
}

-(void)setArrUrl:(NSArray *)arrUrl {
    _arrUrl = arrUrl;
}

-(void)setArr:(NSArray *)arr {
    //轮播器
    
    _arr=@[@"http://wimg.huodongxing.com/Content/app/appom/622492454354615.jpg",
               @"http://wimg.huodongxing.com/Content/app/appom/882472505355506.jpg",
               @"http://wimg.huodongxing.com/Content/app/appom/882478460206044.jpg",
               @"http://wimg.huodongxing.com/Content/app/appom/152482432954477.jpeg",
               @"http://wimg.huodongxing.com/Content/app/appom/512474436408896.jpg",
               @"http://wimg.huodongxing.com/Content/app/appom/462463719205212.jpg"
               ];
    
    SDCycleScrollView *view = [SDCycleScrollView cycleScrollViewWithFrame:CGRectMake(0, 0, self.bounds.size.width, 120) imageURLStringsGroup:self.arr];
//    SDCycleScrollView *view=[SDCycleScrollView cycleScrollViewWithFrame:CGRectMake(0, 0, self.bounds.size.width, 120) imageNamesGroup:self.arr];
    [self addSubview:view];
    self.myView = view;
    
}


- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
